#include "te_local.h"

// Here be commands added to the game for fun and lollygagging


/*
===========================
vid_restart
Restarts the video system, allowing resolution, etc to change
===========================
*/
ConUsageString Cmd_VidRestart_Usage("Restarts the video system", 0, "vid_restart");
void Cmd_VidRestart_f(const CmdArgs &args)
{
	GameEngine::GetSingleton()->Video_Restart();
}


/*
===========================
snd_restart
Restarts the FMOD ex sound system, allowing startup variables to refresh
NOT YET IMPLEMENTED
===========================
*/
ConUsageString Cmd_SndRestart_Usage("Restarts the sound system", 0, "snd_restart");
void Cmd_SndRestart_f(const CmdArgs &args)
{
	Console::Print("NOT YET IMPLEMENTED\n");
}

/*
===========================
AddEngineCommands
Adds all of the commands to the cmdSystemEx for the engine
Should only be called at startup.
===========================
*/
void AddEngineCommands(void)
{
	cmdSystemEx->AddCmd("vid_restart", Cmd_VidRestart_f, CMD_RENDERER|CMD_ENGINE, &Cmd_VidRestart_Usage);
	cmdSystemEx->AddCmd("snd_restart", Cmd_SndRestart_f, CMD_SOUND|CMD_ENGINE, &Cmd_SndRestart_Usage);
}
/*
===========================
RemoveEngineCommands
Removes the commands from the cmdSystemEx for the engine
Should only be called at shutdown.
===========================
*/
void RemoveEngineCommands(void)
{
	cmdSystemEx->RemoveCmd("vid_restart");
	cmdSystemEx->RemoveCmd("snd_restart");
}